package com.cqeec.myblog.service;

import java.sql.SQLException;
import java.util.List;
import java.util.Map;

import com.cqeec.myblog.model.Article;
import com.cqeec.myblog.model.DataDictionary;

/**
 * 文章服务类(业务逻辑处理类)。
 * 
 * @author TLF。
 *
 */
public interface ArticleService {
	public void addArticleType(DataDictionary dd) throws ClassNotFoundException, SQLException;

	public List<DataDictionary> getArticleType() throws ClassNotFoundException, SQLException;

	public List<Article> getAllArticle();

	public void saveArticle(Article article) throws ClassNotFoundException, SQLException;

	public void delArticleType(String id) throws ClassNotFoundException, SQLException;

	public List<Article> getArticleByType(String type) throws ClassNotFoundException, SQLException;

	public List<Article> getArticleByPage(int pageSize, int pageNumber) throws ClassNotFoundException, SQLException;

	public int getRecordsTotalNumber() throws ClassNotFoundException, SQLException;

	public int getRecordsTotalNumber(String type) throws ClassNotFoundException, SQLException;

	public List<Article> getArticleByPage(int pageSize, int pageNumber, String type)
			throws ClassNotFoundException, SQLException;

	public Map<String,Integer> getArticleTypeAndTotal() throws ClassNotFoundException, SQLException;

	public Article getArticle(String id) throws ClassNotFoundException, SQLException;
}
